package com.linkai.JUC._15_single;

/**
 * @Description: 静态内部类实现单例模式
 * @Author: 林凯
 * @Date: 2021/10/26 12:09
 */
public class _03_Holder {

    private _03_Holder() {
    }

    public static class InnerClass {
        private static final _03_Holder HOLDER = new _03_Holder();
    }

    public static _03_Holder getInstance() {
        // 返回内部类中的 HOLDER 对象
        return InnerClass.HOLDER;
    }
}
